function GetDateStep() {

	var myData = [
			['1', '上班时间', "12:06 January 2010", "12:06 January 2012", '09:00:00-18:00:00'],
			['2', '上班时间', "12:06 January 2010", "12:06 January 2012", '09:00:00-18:00:00'],
			['3', '上班时间', "12:06 January 2010", "12:06 January 2012", '09:00:00-18:00:00'],
			['4', '上班时间', "12:06 January 2010", "12:06 January 2012", '09:00:00-18:00:00'],
			['5', '上班时间', "12:06 January 2010", "12:06 January 2012", '09:00:00-18:00:00']


	];


	var store = new Ext.data.ArrayStore({
				fields : [{
							name : 'id'
						}, {
							name : 'name'
						}, {
							name : 'start_date'
						}, {
							name : 'end_date'
						}, {
							name : 'RecurringEntries'
						}]
			});
			
	store.loadData(myData);
	
	var sm = new Ext.grid.CheckboxSelectionModel();
	var grid = new Ext.grid.GridPanel({
				store : store,
				columns : [sm, {
							id : 'id',
							header : 'id',
							width : 10,
							sortable : true,
							dataIndex : 'id',
							hidden : true
						}, {
							header : 'Name',
							width : 100,
							sortable : true,
							dataIndex : 'name'
						}, {
							header : 'Start Time',
							width : 120,
							sortable : true,
							dataIndex : 'start_date'
						}, {
							header : 'End Time',
							width : 120,
							sortable : true,
							dataIndex : 'end_date'
						}, {
							header : 'Recurring Entries',
							width : 100,
							sortable : true,
							dataIndex : 'RecurringEntries'
						}],
				sm : sm,
				tbar : [{
				            text:'添加',
				            tooltip : '添加',
				            iconCls: 'add', 
							handler : function() {
								DateStepWindows(datestepReturn);
							}
				        },'-',{
							text : '编辑',
							tooltip : '编辑',
							iconCls : 'modify',
							handler : function() {
								DateStepWindows(datestepReturn);
							}
						}, '-', {
							text : '删除',
							tooltip : '删除',
							iconCls : 'delete',
							ref : '../removeBtn',
							disabled : true,
							handler : function() {
								var s = grid.getSelectionModel().getSelections();
								for (var i = 0; r = s[i]; i++) {
									store.remove(r);
								}
							}
						}, '-', {
							text : '刷新',
							tooltip : '刷新',
							iconCls : 'refresh',
							handler : function() {							
								store.loadData(myData);
							}
						}],
				
				stripeRows : true,
				autoExpandColumn : 'id',
				stateful : true,
				stateId : 'datestepgrid'
			});
	grid.getSelectionModel().on('selectionchange', function(sm) {
				grid.removeBtn.setDisabled(sm.getCount() < 1);
			});

	function datestepReturn(data){
		var jsondata = Ext.util.JSON.decode(data);
		
	}

	function reflashgriad(page) {
	}
	
	
	
	return grid;
}


function DateStepWindows(datestepReturn){
	var states1 = [
		['1993'],
		['1994'],
		['1995'],
		['1996'],
		['1997'],
		['1998'],
		['1999'],
		['2000'],
		['2001'],
		['2002'],
		['2003'],
		['2004'],
		['2005'],
		['2006'],
		['2007'],
		['2008'],
		['2009'],
		['2010'],
		['2011'],
		['2012'],
		['2013'],
		['2014'],
		['2015'],
		['2016'],
		['2017'],
		['2018'],
		['2019'],
		['2020'],
		['2021'],
		['2022'],
		['2023'],
		['2024'],
		['2025'],
		['2026'],
		['2027'],
		['2028'],
		['2029'],
		['2030'],
		['2031'],
		['2032'],
		['2033'],
		['2034'],
		['2035']
	]
	var states2 = [
		['1', '一月'],
		['2', '二月'],
		['3', '三月'],
		['4', '四月'],
		['5', '五月'],
		['6', '六月'],
		['7', '七月'],
		['8', '八月'],
		['9', '九月'],
		['10', '十月'],
		['11', '十一月'],
		['12', '十二月']
		];
	var states3 = [

		['1', '1日'],
		['2', '2日'],
		['3', '3日'],
		['4', '4日'],
		['5', '5日'],
		['6', '6日'],
		['7', '7日'],
		['8', '8日'],
		['9', '9日'],
		['10', '10日'],
		['11', '11日'],
		['12', '12日'],
		['13', '13日'],
		['14', '14日'],
		['15', '15日'],
		['16', '16日'],
		['17', '17日'],
		['18', '18日'],
		['19', '19日'],
		['20', '20日'],
		['21', '21日'],
		['22', '22日'],
		['23', '23日'],
		['24', '24日'],
		['25', '25日'],
		['26', '26日'],
		['27', '27日'],
		['28', '28日'],
		['29', '29日'],
		['30', '30日'],
		['31', '31日']
		];
	var states4=[
		['00'],
		['01'],
		['02'],
		['03'],
		['04'],
		['05'],
		['06'],
		['07'],
		['08'],
		['09'],
		['10'],
		['11'],
		['12'],
		['13'],
		['14'],
		['15'],
		['16'],
		['17'],
		['18'],
		['19'],
		['20'],
		['21'],
		['22'],
		['23']
		];
	var states5=[
		['00'],
		['01'],
		['02'],
		['03'],
		['04'],
		['05'],
		['06'],
		['07'],
		['08'],
		['09'],
		['10'],
		['11'],
		['12'],
		['13'],
		['14'],
		['15'],
		['16'],
		['17'],
		['18'],
		['19'],
		['20'],
		['21'],
		['22'],
		['23'],
		['24'],
		['25'],
		['26'],
		['27'],
		['28'],
		['29'],
		['30'],
		['31'],
		['32'],
		['33'],
		['34'],
		['35'],
		['36'],
		['37'],
		['38'],
		['39'],
		['40'],
		['41'],
		['42'],
		['43'],
		['44'],
		['45'],
		['46'],
		['47'],
		['48'],
		['49'],
		['50'],
		['51'],
		['52'],
		['53'],
		['54'],
		['55'],
		['56'],
		['57'],
		['58'],
		['59']
		];

	var date_north = {
		xtype: 'fieldset',
		margins:'5 5 5 5',
		layout: 'form',
		height: 240,
		region:'north',
		title: '基本信息',
		items: [
		{
			xtype: 'textfield',
			name: 'sdname',
			id  : 'sdname',
			fieldLabel: 'Name',
			anchor: '100%'
		},new Ext.form.CompositeField({ 
				fieldLabel: 'Start Time', 
				items: [ 
						
						{ 
				        xtype: 'radio',
								name: 'startradio',
								id  : 'startnow',
				        boxLabel:'Start now',
				        checked: true
				    }
				     
				] 
		}),new Ext.form.CompositeField({ 
				items: [ 
						
						{ 
				        xtype: 'radio',
								name: 'startradio',
								id  : 'startat',
				        boxLabel:'Start at'
				    }
				     
				] 
		}),new Ext.form.CompositeField({ 
				items: [ 
						{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Month:',
							width : 40
						},{
							xtype : 'combo',
							name : 'month',
							frame : true,
							id : 'month',
							store : new Ext.data.ArrayStore({
									fields : ['abbr', 'state'],
									data : states2
								}),
							valueField : 'abbr',
							displayField : 'state',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '1',
							editable : false,
							width : 100
						},{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Day:',
							width : 40
						},{
							xtype : 'combo',
							name : 'day',
							frame : true,
							id : 'day',
							store : new Ext.data.ArrayStore({
									fields : ['abbr', 'state'],
									data : states3
								}),
							valueField : 'abbr',
							displayField : 'state',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '1',
							editable : false,
							width : 100
						},{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Year:',
							width : 35
						},{
							xtype : 'combo',
							name : 'year',
							frame : true,
							id : 'year',
							store : new Ext.data.ArrayStore({
									fields : ['value'],
									data : states1
								}),
							valueField : 'value',
							displayField : 'value',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '2012',
							editable : false,
							width : 100
						}
				     
				] 
		}),new Ext.form.CompositeField({ 
				items: [ 
						{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Hour:',
							width : 40
						},{
							xtype : 'combo',
							name : 'Hour',
							frame : true,
							id : 'Hour',
							store : new Ext.data.ArrayStore({
									fields : ['value'],
									data : states4
								}),
							valueField : 'value',
							displayField : 'value',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '00',
							editable : false,
							width : 100
						},{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Minute:',
							width : 40
						},{
							xtype : 'combo',
							name : 'Minute',
							frame : true,
							id : 'Minute',
							store : new Ext.data.ArrayStore({
									fields : ['value'],
									data : states5
								}),
							valueField : 'value',
							displayField : 'value',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '00',
							editable : false,
							width : 100
						}
				     
				] 
		}),new Ext.form.CompositeField({ 
				fieldLabel: 'End Time', 
				items: [ 
						
						{ 
				        xtype: 'radio',
								name: 'startradio1',
								id  : 'startnow1',
				        boxLabel:'Naver end',
				        checked: true
				    }
				     
				] 
		}),new Ext.form.CompositeField({ 
				items: [ 
						
						{ 
				        xtype: 'radio',
								name: 'startradio1',
								id  : 'startat1',
				        boxLabel:'End at(inclusive)'
				    }
				     
				] 
		}),new Ext.form.CompositeField({ 
				items: [ 
						{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Month:',
							width : 40
						},{
							xtype : 'combo',
							name : 'month1',
							frame : true,
							id : 'month1',
							store : new Ext.data.ArrayStore({
									fields : ['abbr', 'state'],
									data : states2
								}),
							valueField : 'abbr',
							displayField : 'state',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '1',
							editable : false,
							width : 100
						},{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Day:',
							width : 40
						},{
							xtype : 'combo',
							name : 'day1',
							frame : true,
							id : 'day1',
							store : new Ext.data.ArrayStore({
									fields : ['abbr', 'state'],
									data : states3
								}),
							valueField : 'abbr',
							displayField : 'state',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '1',
							editable : false,
							width : 100
						},{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Year:',
							width : 35
						},{
							xtype : 'combo',
							name : 'year1',
							frame : true,
							id : 'year1',
							store : new Ext.data.ArrayStore({
									fields : ['value'],
									data : states1
								}),
							valueField : 'value',
							displayField : 'value',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '2012',
							editable : false,
							width : 100
						}
				     
				] 
		}),new Ext.form.CompositeField({ 
				items: [ 
						{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Hour :',
							width : 40
						},{
							xtype : 'combo',
							name : 'Hour1',
							frame : true,
							id : 'Hour1',
							store : new Ext.data.ArrayStore({
									fields : ['value'],
									data : states4
								}),
							valueField : 'value',
							displayField : 'value',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '00',
							editable : false,
							width : 100
						},{
							xtype: 'label',
							style:'padding-top: 5px; ', 
							text:'Minute:',
							width : 40
						},{
							xtype : 'combo',
							name : 'Minute1',
							frame : true,
							id : 'Minute1',
							store : new Ext.data.ArrayStore({
									fields : ['value'],
									data : states5
								}),
							valueField : 'value',
							displayField : 'value',
							typeAhead : true,
							mode : 'local',
							triggerAction : 'all',
							value : '00',
							editable : false,
							width : 100
						}
				     
				] 
		})

		]
	};


	
	var weekData = [
			['1', 'daily 00:00 through 23:59'],
			['2', 'daily 00:00 through 23:59'],
			['3', 'daily 00:00 through 23:59'],
			['4', 'daily 00:00 through 23:59'],
			['5', 'daily 00:00 through 23:59']
	];


	var weekStore = new Ext.data.ArrayStore({
				fields : [{
							name : 'id'
						}, {
							name : 'RecurringEntries'
						}]
			});

	weekStore.loadData(weekData);
	var sm = new Ext.grid.CheckboxSelectionModel();
	var weekgrid = new Ext.grid.GridPanel({
				store : weekStore,
				columns : [sm, {
							id : 'id',
							header : 'id',
							width : 10,
							sortable : true,
							dataIndex : 'id',
							hidden : true
						}, {
							header : 'Recurring Entries',
							width : 300,
							sortable : true,
							dataIndex : 'RecurringEntries'
						}],
				sm : sm,
				tbar : [{
							text : '添加',
							tooltip : '添加',
							iconCls : 'add',
							handler : function() {
								WeekTimeWindows(weektimeReturn);
							}
						},'-',{
							text : '编辑',
							tooltip : '编辑',
							iconCls : 'modify',
							handler : function() {
								WeekTimeWindows(weektimeReturn);
							}
						},'-',{
							text : '删除',
							tooltip : '删除',
							iconCls : 'delete',
							ref : '../removeBtn',
							disabled : true,
							handler : function() {
							}
						}],
				stripeRows : true,
				autoExpandColumn : 'id',
				region : 'center'
			});
	function weektimeReturn(data){
		var jsondata = Ext.util.JSON.decode(data);
		
	}

	var date_center = {
		xtype: 'fieldset',
		margins:'5 5 5 5',
		title: 'Recurring Time Ranges',
		layout : 'border',
		region:'center',
		items: [weekgrid]
	};
	var dateWindows = new Ext.Window({
				layout : 'border',
				width : 600,
				height : 500,
				title : "时段",
				modal : true,
				resizable : true,
				maximizable : true,
				iconCls : 'time',
				items : [date_north,date_center],
				plain : true
			});
	dateWindows.addButton({
				text : "确定",
				handler : function() {
					var data = "{name:'" + Ext.get("name").getValue() + "',start_date:'" + Ext.get("start_date").getValue() + "',end_date:'" + Ext.get("end_date").getValue() + "'}";
					datestepReturn(data);
					dateWindows.close();
				}
			});
	dateWindows.addButton({
				text : '取 消',
				handler : function() {
					dateWindows.close();
				}
			});
	dateWindows.show();
}
function WeekTimeWindows(weektimeReturn){

	var states3=[
		['Sunday'],
		['Monday'],
		['Tuesday'],
		['Wednesday'],
		['Thursday'],
		['Friday'],
		['Saturday']
	];
	var states4=[
		['00'],
		['01'],
		['02'],
		['03'],
		['04'],
		['05'],
		['06'],
		['07'],
		['08'],
		['09'],
		['10'],
		['11'],
		['12'],
		['13'],
		['14'],
		['15'],
		['16'],
		['17'],
		['18'],
		['19'],
		['20'],
		['21'],
		['22'],
		['23']
		];
	var states5=[
		['00'],
		['01'],
		['02'],
		['03'],
		['04'],
		['05'],
		['06'],
		['07'],
		['08'],
		['09'],
		['10'],
		['11'],
		['12'],
		['13'],
		['14'],
		['15'],
		['16'],
		['17'],
		['18'],
		['19'],
		['20'],
		['21'],
		['22'],
		['23'],
		['24'],
		['25'],
		['26'],
		['27'],
		['28'],
		['29'],
		['30'],
		['31'],
		['32'],
		['33'],
		['34'],
		['35'],
		['36'],
		['37'],
		['38'],
		['39'],
		['40'],
		['41'],
		['42'],
		['43'],
		['44'],
		['45'],
		['46'],
		['47'],
		['48'],
		['49'],
		['50'],
		['51'],
		['52'],
		['53'],
		['54'],
		['55'],
		['56'],
		['57'],
		['58'],
		['59']
		];
	var WeekTime_center = {
		xtype: 'fieldset',
		margins:'5 5 5 5',
		layout : 'form',
		region:'center',
		bodyStyle : 'padding:10px;',
		items: [
		{
		            xtype:'fieldset',
		            checkboxToggle:true,
		            title: 'Specify days of the week and times on which this reccurring range will be active',
		            id:'type1',
		            autoHeight:true,
		            collapsed: false,
		            labelWidth : 120,
		            items :[
		            	{
														xtype: 'label',
														style:'padding-top: 4px; font-size: 10pt;', 
														text:'For example, use this option when you want the time range to be active Monday through Thursday,from 8:00 throught 16:59,only. ',
														width : 530
									},{
														xtype: 'label',
														style:'padding-top: 4px; font-size: 10pt;', 
														text:' ',
														width : 530
									},
		            	new Ext.form.CompositeField({ 
											fieldLabel: 'Days of the Week', 
											items: [ 
													
													{ 
											        xtype: 'radio',
															name: 'weekradio',
															id  : 'Everyday',
											        boxLabel:'Every day',
											        checked: true
											    }
											     
											] 
									}),new Ext.form.CompositeField({ 
											items: [ 
													{ 
											        xtype: 'radio',
															name: 'weekradio',
															id  : 'Weekdays',
											        boxLabel:'Weekdays'
											    }
											] 
									}),new Ext.form.CompositeField({ 
											items: [ 
													{ 
											        xtype: 'radio',
															name: 'weekradio',
															id  : 'Weekends',
											        boxLabel:'Weekends'
											    }
											] 
									}),new Ext.form.CompositeField({ 
											items: [ 
													{ 
											        xtype: 'radio',
															name: 'weekradio',
															id  : 'thesedays',
											        boxLabel:'On these days of the week:'
											    }
											] 
									}),new Ext.form.CompositeField({ 
										    items: [ 
										    		{ 
										            xtype: 'checkbox',
										            boxLabel:'Mon'
														},{ 
										            xtype: 'checkbox',
										            boxLabel:'Tue'
														},{ 
										            xtype: 'checkbox',
										            boxLabel:'Wed'
														},{ 
										            xtype: 'checkbox',
										            boxLabel:'Thu'
														},{ 
										            xtype: 'checkbox',
										            boxLabel:'Fri'
														},{ 
										            xtype: 'checkbox',
										            boxLabel:'Sat'
														},{ 
										            xtype: 'checkbox',
										            boxLabel:'Sun'
														}
										         
										    ] 
									}),new Ext.form.CompositeField({ 
											fieldLabel: 'Daily Start Time', 
											items: [ 
													{
														xtype: 'label',
														style:'padding-top: 5px; ', 
														text:'Hour :',
														width : 40
													},{
														xtype : 'combo',
														name : 'Hour12',
														frame : true,
														id : 'Hour12',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states4
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '00',
														editable : false,
														width : 100
													},{
														xtype: 'label',
														style:'padding-top: 5px; ', 
														text:'Minute:',
														width : 40
													},{
														xtype : 'combo',
														name : 'Minute12',
														frame : true,
														id : 'Minute12',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states5
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '00',
														editable : false,
														width : 100
													}
											     
											] 
									}),new Ext.form.CompositeField({ 
											fieldLabel: 'Daily End Time', 
											items: [ 
													{
														xtype: 'label',
														style:'padding-top: 5px; ', 
														text:'Hour :',
														width : 40
													},{
														xtype : 'combo',
														name : 'Hour13',
														frame : true,
														id : 'Hour13',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states4
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '23',
														editable : false,
														width : 100
													},{
														xtype: 'label',
														style:'padding-top: 5px; ', 
														text:'Minute:',
														width : 40
													},{
														xtype : 'combo',
														name : 'Minute13',
														frame : true,
														id : 'Minute13',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states5
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '59',
														editable : false,
														width : 100
													}
											     
											] 
									})
		            ],
		            listeners:{'collapse':function(obj){
                        Ext.getCmp('type2').expand();     
                        },
                        'expand':function(obj){
                        Ext.getCmp('type2').collapse(true); 
                        }
                    }
		        },{
		            xtype:'fieldset',
		            checkboxToggle:true,
		            title: 'Specify a weekly interval when this recurring range will be active',
		            id:'type2',
		            autoHeight:true,
		            collapsed: true,
		            items :[
		            	{
														xtype: 'label',
														style:'padding-top: 4px; font-size: 10pt;', 
														text:'For example, use this option when you want the time range to be activecontinuously from Monday at 8:00 through Friday at 16:59. ',
														width : 530
									},{
														xtype: 'label',
														style:'padding-top: 4px; font-size: 10pt;', 
														text:' ',
														width : 530
									},
		            	new Ext.form.CompositeField({ 
											fieldLabel: 'Weekly Interval', 
											items: [ 
													{
														xtype: 'label',
														style:'padding-top: 4px; ', 
														text:'From:',
														width : 40
													},{
														xtype : 'combo',
														name : 'week12',
														frame : true,
														id : 'week12',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states3
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : 'Monday',
														editable : false,
														width : 100
													},{
														xtype: 'label',
														style:'padding-top: 4px; ', 
														text:'Hour :',
														width : 40
													},{
														xtype : 'combo',
														name : 'Hour22',
														frame : true,
														id : 'Hour22',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states4
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '00',
														editable : false,
														width : 100
													},{
														xtype: 'label',
														style:'padding-top: 4px; ', 
														text:'Minute:',
														width : 40
													},{
														xtype : 'combo',
														name : 'Minute22',
														frame : true,
														id : 'Minute22',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states5
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '00',
														editable : false,
														width : 100
													}
											     
											] 
									}),new Ext.form.CompositeField({ 
											items: [ 
													{
														xtype: 'label',
														style:'padding-top: 4px; ', 
														text:'From:',
														width : 40
													},{
														xtype : 'combo',
														name : 'week22',
														frame : true,
														id : 'week22',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states3
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : 'Friday',
														editable : false,
														width : 100
													},{
														xtype: 'label',
														style:'padding-top: 4px; ', 
														text:'Hour :',
														width : 40
													},{
														xtype : 'combo',
														name : 'Hour23',
														frame : true,
														id : 'Hour23',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states4
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '23',
														editable : false,
														width : 100
													},{
														xtype: 'label',
														style:'padding-top: 4px; ', 
														text:'Minute:',
														width : 40
													},{
														xtype : 'combo',
														name : 'Minute23',
														frame : true,
														id : 'Minute23',
														store : new Ext.data.ArrayStore({
																fields : ['value'],
																data : states5
															}),
														valueField : 'value',
														displayField : 'value',
														typeAhead : true,
														mode : 'local',
														triggerAction : 'all',
														value : '59',
														editable : false,
														width : 100
													}
											     
											] 
									})
		            ],
		            listeners:{'collapse':function(obj){
                        Ext.getCmp('type1').expand();     
                        },
                        'expand':function(obj){
                        Ext.getCmp('type1').collapse(true); 
                        }
                    }
		        }
	
		]
	};

	var WeekTimeWindows = new Ext.Window({
				layout : 'border',
				width : 600,
				height : 400,
				title : "Recurring Time Ranges",
				modal : true,
				resizable : true,
				maximizable : true,
				iconCls : 'time',
				items : [WeekTime_center],
				plain : true
				
			});
	WeekTimeWindows.addButton({
				text : "确定",
				handler : function() {
					var data = "{week:'" + Ext.getCmp("week").getValue() + "',start_time:'" + Ext.get("start_time").getValue() + "',end_time:'" + Ext.get("end_time").getValue() + "'}";
					weektimeReturn(data);
					WeekTimeWindows.close();
				}
			});
	WeekTimeWindows.addButton({
				text : '取 消',
				handler : function() {
					WeekTimeWindows.close();
				}
			});
	WeekTimeWindows.show();
}	